﻿@model YHWE.Web.Models.SiteLibrary

@{
    ViewBag.Title = "Edit";
}

<h2>@Model.name 编辑</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

<form action="Edit" method="post">
    @Html.ValidationSummary(true)


@*        @Html.Hidden("ID", Model.ID);*@
        <input type="hidden" name="ID" value="@Model.ID" />

        <div class="editor-field">

            <textarea id="companyIntro" name="value" style="width:100%; height:400px;">@Model.value</textarea>
            @Html.ValidationMessageFor(model => model.value)
        </div>



        <p>
            <input type="submit" value="Save" />
        </p>

</form>


@section Head{
<script type="text/javascript">
    $(document).ready(function () {

        $('#companyIntro').xheditor({
            skin: 'nostyle',
            tools: "mytools",
            upBtnText: '上传',
            upLinkUrl: '/upload/siteLibrary',
            upImgUrl: '/upload/siteLibrary',
            upFlashUrl: '/upload/siteLibrary',
            upMediaUrl: '/upload/siteLibrary'
        });
    })
</script>
}